#ifndef QQ_APPLICATION
#define QQ_APPLICATION

#include <qapplication.h>

#include "core/QQSettings.h"

#include "storage/QQStorage.h"

#include "network/QQNetWork.h"

#include "entry/QQEntryController.h"
#include "main/QQClientController.h"

class QQAppEventFilter :public QObject
{
	Q_OBJECT
public:
	QQAppEventFilter(QObject* parent = nullptr);
	~QQAppEventFilter() = default;
signals:
	void mousePress(QPoint pos, Qt::MouseButton type);
protected:
	bool eventFilter(QObject* watched, QEvent* event) override;
};

class QQApplication :public QApplication
{
	Q_OBJECT
public:
	QQApplication(int& argc, char** argv, int = ApplicationFlags);
	~QQApplication();
private slots:
	void doEntrySuccess(const QString& account);
private:
	QQAppEventFilter* mAppEventFilter;
	QQClientController* mClientController;
	QQEntryController* mEntryContorller;
};
#endif // !QQ_APPLICATION
